#WAR包名称
PROJECT_NM=tjy-task
DESTRIBUTE_PROJECT_NM=ROOT
SERVERPATH=/app/server
SERVER_NM=tjy-task
echo =============shut down ======
cd ${SERVERPATH}/${SERVER_NM}/bin
./shutdown.sh
echo ------kill -9 ./shutdown.sh
ID=`ps -ef | grep java | grep ${SERVERPATH}/${SERVER_NM}/|awk '{print $2}'`
echo $ID  
echo "---------------"  
for id in $ID  
do  
  kill -9 $id  
  echo "killed$id"  
done  
echo "---------------" 
echo =============publish ======

cd ${SERVERPATH}/${SERVER_NM}/webapps/${DESTRIBUTE_PROJECT_NM}

unzip ${SERVERPATH}/${SERVER_NM}/webapps/${DESTRIBUTE_PROJECT_NM}/${PROJECT_NM}.war

echo =============start======
cd ${SERVERPATH}/${SERVER_NM}/bin
./startup.sh

echo date
date
echo =============sccess======

